Data processing systems, such as microcontrollers and microprocessors, are becoming increasingly complex and may include a large number of peripherals, busses, memories, and control units. Therefore, the control and operation of these many units within one data processing system is becoming more complex. In order to debug operable code used for controlling a data processing system and its constituent parts, it is often necessary to use a debug and tracing program.
Typical software debugging involves using an emulation system. This often requires the manufacture of two devices; a first for the user and another for debugging the code, where the debug version of the device allows access to information that is otherwise hidden from the user. Emulation systems are often complicated and cumbersome. Additionally, emulators are costly and are not easily transported for field debugging. As these tools developed, designers were able to allow debugging in the background as the device operated in a user mode. Another type of debugging is done with an on-chip emulator. On-chip emulation has the drawback of requiring silicon area to provide an emulator which will not be used by the user, and also requires an input/output (I/O) interface.
In addition to the normal complexity of data processing systems, specific memory areas within the data processor may be access protected. Access protection may be used to protect certain memory areas from being written to, read from, or to prevent code stored therein from being executed. Access protection may involve a combination of these protections, and may certain users access while denying access to others. While emulators, both on and off the device, offer extensive debug capability, they often compromise access protection and the security of the code and data stored in a device by offering a "backdoor" into the device.
It is desirable to be able to debug a data processing system while maintaining the access protection of these specific memory areas and to maintain the security of the system. It is also desirable to have a convenient method of debugging device code in the field without the hardware typically associated with emulation.